3.214 \(\int \frac{\csc (x)}{-\cot (x)+\csc (x)} \, dx\)

Optimal. Leaf size=12 \[ -\frac{\sin (x)}{1-\cos (x)} \]

[Out]

-(Sin[x]/(1 - Cos[x]))

________________________________________________________________________________________

Rubi [A]  time = 0.029823, antiderivative size = 12, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 2, integrand size = 12, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.167, Rules used = {3166, 2648} \[ -\frac{\sin (x)}{1-\cos (x)} \]

Antiderivative was successfully verified.

[In]

Int[Csc[x]/(-Cot[x] + Csc[x]),x]

[Out]

-(Sin[x]/(1 - Cos[x]))

Rule 3166

Int[csc[(d_.) + (e_.)*(x_)]^(n_.)*((a_.) + csc[(d_.) + (e_.)*(x_)]*(b_.) + cot[(d_.) + (e_.)*(x_)]*(c_.))^(m_)
, x_Symbol] :> Int[1/(b + a*Sin[d + e*x] + c*Cos[d + e*x])^n, x] /; FreeQ[{a, b, c, d, e}, x] && EqQ[m + n, 0]
 && IntegerQ[n]

Rule 2648

Int[((a_) + (b_.)*sin[(c_.) + (d_.)*(x_)])^(-1), x_Symbol] :> -Simp[Cos[c + d*x]/(d*(b + a*Sin[c + d*x])), x]
/; FreeQ[{a, b, c, d}, x] && EqQ[a^2 - b^2, 0]

Rubi steps

\begin{align*} \int \frac{\csc (x)}{-\cot (x)+\csc (x)} \, dx &=\int \frac{1}{1-\cos (x)} \, dx\\ &=-\frac{\sin (x)}{1-\cos (x)}\\ \end{align*}

Mathematica [A]  time = 0.0067818, size = 8, normalized size = 0.67 \[ -\cot \left (\frac{x}{2}\right ) \]

Antiderivative was successfully verified.

[In]

Integrate[Csc[x]/(-Cot[x] + Csc[x]),x]

[Out]

-Cot[x/2]

________________________________________________________________________________________

Maple [A]  time = 0.054, size = 9, normalized size = 0.8 \begin{align*} - \left ( \tan \left ({\frac{x}{2}} \right ) \right ) ^{-1} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(csc(x)/(-cot(x)+csc(x)),x)

[Out]

-1/tan(1/2*x)

________________________________________________________________________________________

Maxima [A]  time = 1.11778, size = 14, normalized size = 1.17 \begin{align*} -\frac{\cos \left (x\right ) + 1}{\sin \left (x\right )} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csc(x)/(-cot(x)+csc(x)),x, algorithm="maxima")

[Out]

-(cos(x) + 1)/sin(x)

________________________________________________________________________________________

Fricas [A]  time = 0.454914, size = 30, normalized size = 2.5 \begin{align*} -\frac{\cos \left (x\right ) + 1}{\sin \left (x\right )} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csc(x)/(-cot(x)+csc(x)),x, algorithm="fricas")

[Out]

-(cos(x) + 1)/sin(x)

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} - \int \frac{\csc{\left (x \right )}}{\cot{\left (x \right )} - \csc{\left (x \right )}}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csc(x)/(-cot(x)+csc(x)),x)

[Out]

-Integral(csc(x)/(cot(x) - csc(x)), x)

________________________________________________________________________________________

Giac [A]  time = 1.13066, size = 11, normalized size = 0.92 \begin{align*} -\frac{1}{\tan \left (\frac{1}{2} \, x\right )} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(csc(x)/(-cot(x)+csc(x)),x, algorithm="giac")

[Out]

-1/tan(1/2*x)